home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / graphic / 1svga.zip / WIN_TEXT.PAS < prev   
Pascal/Delphi Source File  |  1994-04-18  |  2KB  |  56 lines

  1. uses Txt;
  2.  
  3. { ─────────────── TextWin1 ─────────────── }
  4. procedure TextWin1(X,Y,LenX,LenY,CBox:integer);
  5. var I:integer;
  6. begin
  7.   PrintText(X,Y,CBox,'╧');
  8.   TextBar(X+1,Y,LenX-2,1,CBox,'╞');
  9.   PrintText(X+LenX-1,Y,CBox,'╨');
  10.   TextBar(X,Y+1,1,LenY-2,CBox,'╫');
  11.   TextBar(X+LenX-1,Y+1,1,LenY-2,CBox,'╪');
  12.   PrintText(X,Y+LenY-1,CBox,'╤');
  13.   TextBar(X+1,Y+LenY-1,LenX-2,1,CBox,'╟');
  14.   PrintText(X+LenX-1,Y+LenY-1,CBox,'╥');
  15.   TextBar(X+1,Y+1,LenX-2,LenY-2,CBox,' ');
  16.   TextShadow(X,Y,LenX,LenY);
  17. end;
  18. { ─────────────── TextWin2 ─────────────── }
  19. procedure TextWin2(X,Y,LenX,LenY,CBox,CTitle:integer;Title:string);
  20. var I:integer;
  21. begin
  22.   TextBar(X,Y,LenX,1,CTitle,' ');
  23.   PrintText(X+(LenX-Length(Title)) shr 1,Y,CTitle,Title);
  24.   TextBar(X,Y+1,1,LenY-2,CBox,'╫');
  25.   TextBar(X+LenX-1,Y+1,1,LenY-2,CBox,'╪');
  26.   PrintText(X,Y+LenY-1,CBox,'╤');
  27.   TextBar(X+1,Y+LenY-1,LenX-2,1,CBox,'╟');
  28.   PrintText(X+LenX-1,Y+LenY-1,CBox,'╥');
  29.   TextBar(X+1,Y+1,LenX-2,LenY-2,CBox,' ');
  30.   TextShadow(X,Y,LenX,LenY);
  31.   for I:=0 to 1 do begin
  32.     PrintText(X+I,Y,CBox,Chr(193+I));
  33.     PrintText(X+I+LenX-2,Y,CBox,Chr(202+I));
  34.   end;
  35. end;
  36.  
  37. var Font_R:array[0..4095] of byte;
  38.     I:integer;
  39. begin
  40.   FileRead('0916sys.fnt',0,256,16,Font_R);
  41.   SetTextFont(16,0,256,Font_R);
  42.   SetFlash(0);
  43.   TextBar(1, 1,80, 1,$3E,' ');
  44.   TextBar(1, 2,80,23,$17,' ');
  45.   TextBar(1,25,80, 1,$3E,' ');
  46.   PrintChar(4, 1,'Show some Text Windows');
  47.   PrintChar(4,25,'Press any key...');
  48.   for I:=0 to 6 do
  49.     TextWin2(4+6*I,3+2*I,30,8,16*(I+1)+I+9,16*(I+9),'Text Window');
  50.   TextWin1( 4,16,30,8,$9B);
  51.   TextWin1(46, 3,30,8,$CF);
  52.   TextWindow1( 6,11,20,8,$CE,$C0,2,' Window ');
  53.   TextWindow2(12,13,20,8,$9F,$F0,' Window ');
  54.   Readln;
  55. end.
  56.